html, body {
    height: 100%;
    padding: 0;
    margin: 0;
    font-family: sans-serif;
    font-size: small;
}
th, td {
    vertical-align: top;
    text-align: left;
}

.info-page {
    display: inline-block;
    position: fixed;
    left: 40px;
    width: calc(100% - 42px);
    height: calc(100% - 40px);
    border: 1px solid rgb(255,184,55);
    border-radius: 10px;
    transition: all 0.35s ease;
    transform: translateY(0);
    z-index: 11;
}
.show-info {
    transform: translateY(-100%);
}

/* Allow full width info screen on narrow screens, e.g. phones */
@media only screen and (max-width: 600px) {
    .info-page {
        left: 0;
        width: 100%;
        height: calc(100% - 40px);
    }
}

#map {
    background-color: #f8f8f8;
    width: 100%;
    height: 100%;
    padding: 0;
    margin: 0;
}

.ol-attribution {
    bottom: 0;
}

.info-page-switcher, .ol-zoom, .geolocate-control, .legend-toggle,
.gcd-gl-control .ol-control {
    background-color: rgba(255,255,255,.4);
}

.ol-control button {
    background-color: #f8f8f8;
    color: #000000;
}
.ol-control button:hover, .ol-control button:focus {
    background-color: #f8f8f8;
    outline: none;
}
.ol-zoom, .geolocate-control, .legend-toggle, .ol-rotate,
.gcd-gl-control .ol-control,
.ol-attribution.ol-control.ol-collapsed,
.ol-attribution.ol-control:not(.ol-collapsed) > button {
    background-color: rgba(255,184,55,.27);
}
.ol-control:hover {
    background-color: rgba(255,184,55,.77);
}

/* "Information page switcher" button */
.info-page-switcher, .info-page-switcher:hover {
    top: 0.5em;
    left: .5em;
    background-color: rgb(56 140 227);
    border-radius: 1.2em;
    padding: 1px;
}
.info-page-switcher:hover {
    background-color: rgb(13 46 58 / 100%);
}
.info-page-switcher button, .info-page-switcher button:hover,
.info-page-switcher button:focus  {
    background-color: #68c0ff;
    border-radius: 0.7em;
    height: 1.4em;
    width: 1.4em;
}
.info-page-switcher button:hover {
    background-color: #1ba0ff;
}

.ol-zoom {
    top: 4.2em;
}

/* "Align North" button (only appears when map is rotated) */
.ol-rotate {
    left: 0.5em;
    right: auto;
    top: 11em;
}

/* "Pan to my location" button */
.geolocate-control {
    top: 15em;
    left: .5em;
}

.ol-scale-line {
    left: auto;
    right: 4px;
    bottom: 27px;
    z-index: 3;
    background: rgba(230,230,230,0.5);
}
.ol-scale-line-inner {
    border: 2px solid black;
    border-top: none;
    color: black;
    font-weight: bold;
}

/* Icon position for legend opener/closer */
.legend-toggle {
    bottom: 0;
    left: 0.5em;
}
.legend-box.switched-off {
    display: none;
}

/* Map Legend Container */
.legend-box {
    position: absolute;
    bottom: 0;
    left: 2.7em;
    padding: 2px;
    padding-left: 0.3em;
    padding-right: 0.3em;
    margin-left: 4px;
    border-radius: 4px;
    max-height: 99%;
    max-width: calc(min(100% - 2.5em - 58px, 300px));
    overflow-x: hidden;
    overflow-y: auto;
    background-color: rgba(241, 241, 241, 0.9);
    z-index: 2;
    user-select: none;
    pointer-events: all;
    border: solid 1px rgb(255,184,55);
}
.legend-box:hover {
    background-color: rgba(241, 241, 241, 0.9);
}
.legend-title {
    padding: 0.3em;
    text-align: center;
    font-weight: bold;
}

/* TBD: add popups when useful data available */
/* Selected Feature Attributes Popup
   (CSS mainly from OpenLayers examples) */
.ol-overlaycontainer {
    pointer-events: none;
 }
.ol-popup {
    position: absolute;
    background-color: white;
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
    padding: 15px;
    border-radius: 10px;
    border: 1px solid #cccccc;
    bottom: 50px;
    left: -50px;
    min-width: 280px;
  }
  .ol-popup:after, .ol-popup:before {
    top: 100%;
    border: solid transparent;
    content: " ";
    height: 0;
    width: 0;
    position: absolute;
    pointer-events: none;
  }
  .ol-popup:after {
    border-top-color: white;
    border-width: 10px;
    left: 48px;
    margin-left: -10px;
  }
  .ol-popup:before {
    border-top-color: #cccccc;
    border-width: 11px;
    left: 48px;
    margin-left: -11px;
  }
  .ol-popup-closer {
    text-decoration: none;
    position: absolute;
    top: 2px;
    right: 8px;
    pointer-events: all;
  }
  .ol-popup-closer:after {
    content: "✖";
  }

/* Popup contents (table of feature attributes) */
.popup-table {
    width: 100%;
/*    border-collapse: collapse; */
}
.popup-table-title {
    margin-bottom: 4px;
    font-weight: bold;
}
.popup-table tr:nth-child(odd) {
        background-color: #cccccc;
}
.popup-table tr:nth-child(even) {
    background-color: #eeeeee;
}
.popup-table td {
    padding-left: 4px;
    padding-right: 4px;
}

.ol-control.buttonActive {
    background-color: #70f370;
}
